Validate Single Number
This request validates a single number prior to uploading to ensure that it has the correct format and assignments.
URL
{{baseUrl}}/api/v2/oc/numbers/action/number-status
HTTP Method
POST
Request Body
Parameter |
Type |
Description |
||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
msTenantId | string | The Microsoft Azure subscription Tenant Id of the customer. | ||||||||||||||||||
telephoneNumbers |
list |
List of phone numbers that are uploaded to the customer. |
||||||||||||||||||
Phone number validation rules are in accordance with E.164. The E.164 format requires the following:
Local telephone number or subscriber number. It has the following structure: [+][country code][area code][subscriber number]. Example of a number with E.164 format in the United States Telephone number: 415 123 1234 E.164 format number: +14151231234
Valid country code, per civic address and/or contact info of the given lead. See Country Dialing Codes. |
Example Request-Single Number
{
"telephoneNumbers": [
"+18333998785"
],
"msTenantId": "f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
Example Response
{
"validationResult": "Success",
"telephoneNumbers": [
{
"telephoneNumber": "+97236004500",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
}
]
}
Example Request-Multiple Numbers
{
"TelephoneNumbers": ["+442074996300","+442074996301","+442074996302","+442074996303","+442074996304","+442074996305","+442074996306", "+442074996307", "+442074996308", "+442074996309"],
"msTenantId": "f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
Example Response
{
"validationResult": "Success",
"telephoneNumbers": [
{
"telephoneNumber": "+442074996300",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996301",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996302",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996303",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996304",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996305",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996306",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996307",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996308",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
},
{
"telephoneNumber": "+442074996309",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
}
]
}
HTTP Responses
■ | 200 OK |
Parameter |
Type |
Description |
|||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
validationResult |
string |
Indicates if the validation execution is successful.
|
|||||||||
telephoneNumbers |
list array |
List array including the following values: telephoneNumber; validationResult, actionRequired, validationDetail, telephoneNumberDetail: numberFound, numberOffering and assignmentStatus |
|||||||||
telephoneNumber |
string |
Indicates the telephone number that was validated. |
|||||||||
validationResult |
string |
Indicates if the validation execution succeeded or failed. |
|||||||||
actionRequired |
string |
Indicates if any actions are required. |
|||||||||
validationDetail |
list array |
List array including the following values:
|
|||||||||
Level |
string |
Error or Information message |
|||||||||
Description |
string |
Description of the message (see examples below) |
|||||||||
telephoneNumberDetail |
list array |
list array including the following values:
|
|||||||||
numberFound |
boolean |
Indicates whether the number is found in the Customer inventory in the Live Platform database.
|
|||||||||
numberOffering |
string |
One of the following values:
|
|||||||||
assignmentStatus |
boolean |
Indicates whether the number has been assigned to the subscriber user in their Teams admin center. |
● | The following status message is displayed for a Direct Routing phone number error: |
{
"validationResult": "Success",
"telephoneNumbers": [
{
"telephoneNumber": "+31235556155",
"validationResult": "Success",
"actionRequired": true,
"validationDetail": [
{
"level": "Warning",
"description": "Number has been found under the same tenant as assigned to a DR-O user. It will be re-assigned as a user. To ensure outbound calls work, OVRP must be removed before the order completes."
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "DirectRoutingOnline",
"assignmentStatus": "UserAssigned"
}
}
]
}
● | The following status message is displayed when numbers have been uploaded to the customer tenant, however not assigned to any user of the customer tenant: |
{
"validationResult": "Failure",
"telephoneNumbers": [
{
"telephoneNumber": "+390810903000",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903001",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903002",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903003",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903004",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903005",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903006",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903007",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903008",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
},
{
"telephoneNumber": "+390810903009",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "Unassigned"
}
}
]
}
● | The following status message is displayed when the number has been uploaded to the customer tenant and has been assigned to a user: |
{
"validationResult": "Failure",
"telephoneNumbers": [
{
"telephoneNumber": "+61398675560",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found as OC in your inventory. Tenant id: 41747617-089b-4128-a9c8-7c9c2c596c25"
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "OperatorConnect",
"assignmentStatus": "UserAssigned"
}
}
]
}
● | The following status message is displayed when the number is not assigned to a Microsoft tenant as 'numberFound' value indicates 'false': |
{
"validationResult": "Success",
"telephoneNumbers": [
{
"telephoneNumber": "+61398675590",
"validationResult": "Success",
"actionRequired": false,
"validationDetail": [],
"telphoneNumberDetail": {
"numberFound": false,
"numberOffering": "",
"assignmentStatus": ""
}
}
]
}
● | The following status message is displayed when the number is assigned to another Microsoft tenant; no further information can be disclosed due tenant privacy restrictions: |
{
"validationResult": "Failure",
"telephoneNumbers": [
{
"telephoneNumber": "+61398675560",
"validationResult": "Failure",
"actionRequired": false,
"validationDetail": [
{
"level": "Error",
"description": "Number has been found under another customer (Teams or ACS). No further actions allowed."
}
],
"telphoneNumberDetail": {
"numberFound": true,
"numberOffering": "",
"assignmentStatus": ""
}
}
]
}
■ | 400 Bad Request: When entering double brackets after the last number. |
{
"phoneNumbers": ["+390810903000","+390810903001","+390810903002","+390810903003", "+390810903004","+390810903005","+390810903006", "+390810903007", "+390810903008", "+390810903009"],
],
"msTenantId": "f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
The following error is generated.
{
"errors": {
"phoneNumbers": [
"Invalid property identifier character: ]. Path 'phoneNumbers', line 3, position 2."
]
},
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-3e619e524b39a55e1682aa6043b7bb5c-49000b50119d5ae1-00"
}
■ | 400 Bad Request: When entering syntax "phoneNumbers" instead of "TelephoneNumbers". |
{
"phoneNumbers": ["+390810903000","+390810903001","+390810903002","+390810903003", "+390810903004","+390810903005","+390810903006", "+390810903007", "+390810903008", "+390810903009"],
"msTenantId": "f94238e5-4f2c-4e1b-8125-2d27122ca75f"
}
The following error is generated.
{
"errors": {
"TelephoneNumbers": [
"The TelephoneNumbers field is required.",
"'Telephone Numbers' must not be empty.",
"TelephoneNumbers should not exceed 500 and each number should be max 100 chars"
]
},
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-68b98f8cbc5bc20849e59574c853673f-e9281f1e69e193c8-00"
}